/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package view;

import java.awt.Image;
import java.util.HashMap;

/**
 * 
 * @author spock
 */
class GraphicsTable
{
    HashMap< Enum, Image > graphics;
    
    // constructor
    GraphicsTable( Enum[] enums, Image[] images ) {
        graphics = new HashMap< Enum, Image >();
        for ( int i = 0; i < enums.length; ++i )
        {
            graphics.put( enums[ i ], images[ i ] );
        }
    }
    
    // retrieves graphics with a key
    Image getGraphic( Enum key )
    {
        return graphics.get( key );
    }
}
